From 296a7c24f946c2c612ddb881a557158f48cbc460 Mon Sep 17 00:00:00 2001 From: Lapo Calamandrei Date: Fri, 26 Feb 2016 13:07:09 +0100 Subject: [PATCH] Adwaita: simplify mixed buttons styling --- gtk/theme/Adwaita/_common.scss | 20 +++----------------- gtk/theme/Adwaita/gtk-contained-dark.css | 16 ++++------------ gtk/theme/Adwaita/gtk-contained.css | 16 ++++------------ 3 files changed, 11 insertions(+), 41 deletions(-) diff --git a/gtk/theme/Adwaita/_common.scss b/gtk/theme/Adwaita/_common.scss index 56877445ad..294267287b 100644 --- a/gtk/theme/Adwaita/_common.scss +++ b/gtk/theme/Adwaita/_common.scss @@ -457,24 +457,10 @@ button { } &.text-button.image-button { - // those buttons needs uneven horizontal padding, we want the icon side - // to have the image-button padding, while the text side the text-button - // one, so we're adding the missing padding to the label depending on - // its position inside the button - padding-left: 0; - padding-right: 0; - - label:first-child { - padding-left: 16px; - padding-right: 0; - } - - label:last-child { - padding-left: 0; - padding-right: 16px; - } + padding-left: 8px; + padding-right: 8px; - image { + label { padding-left: 8px; padding-right: 8px; } diff --git a/gtk/theme/Adwaita/gtk-contained-dark.css b/gtk/theme/Adwaita/gtk-contained-dark.css index 3b13a93ff9..62094f69d5 100644 --- a/gtk/theme/Adwaita/gtk-contained-dark.css +++ b/gtk/theme/Adwaita/gtk-contained-dark.css @@ -489,18 +489,10 @@ notebook > header > tabs > arrow, headerbar button.titlebutton, padding-right: 16px; } notebook > header > tabs > arrow.text-button.image-button, headerbar button.text-button.image-button.titlebutton, .titlebar button.text-button.image-button.titlebutton, button.text-button.image-button { - padding-left: 0; - padding-right: 0; } - notebook > header > tabs > arrow.text-button.image-button label:first-child, headerbar button.text-button.image-button.titlebutton label:first-child, - .titlebar button.text-button.image-button.titlebutton label:first-child, button.text-button.image-button label:first-child { - padding-left: 16px; - padding-right: 0; } - notebook > header > tabs > arrow.text-button.image-button label:last-child, headerbar button.text-button.image-button.titlebutton label:last-child, - .titlebar button.text-button.image-button.titlebutton label:last-child, button.text-button.image-button label:last-child { - padding-left: 0; - padding-right: 16px; } - notebook > header > tabs > arrow.text-button.image-button image, headerbar button.text-button.image-button.titlebutton image, - .titlebar button.text-button.image-button.titlebutton image, button.text-button.image-button image { + padding-left: 8px; + padding-right: 8px; } + notebook > header > tabs > arrow.text-button.image-button label, headerbar button.text-button.image-button.titlebutton label, + .titlebar button.text-button.image-button.titlebutton label, button.text-button.image-button label { padding-left: 8px; padding-right: 8px; } button.osd { diff --git a/gtk/theme/Adwaita/gtk-contained.css b/gtk/theme/Adwaita/gtk-contained.css index e8e2ee638e..4544b3a515 100644 --- a/gtk/theme/Adwaita/gtk-contained.css +++ b/gtk/theme/Adwaita/gtk-contained.css @@ -489,18 +489,10 @@ notebook > header > tabs > arrow, headerbar button.titlebutton, padding-right: 16px; } notebook > header > tabs > arrow.text-button.image-button, headerbar button.text-button.image-button.titlebutton, .titlebar button.text-button.image-button.titlebutton, button.text-button.image-button { - padding-left: 0; - padding-right: 0; } - notebook > header > tabs > arrow.text-button.image-button label:first-child, headerbar button.text-button.image-button.titlebutton label:first-child, - .titlebar button.text-button.image-button.titlebutton label:first-child, button.text-button.image-button label:first-child { - padding-left: 16px; - padding-right: 0; } - notebook > header > tabs > arrow.text-button.image-button label:last-child, headerbar button.text-button.image-button.titlebutton label:last-child, - .titlebar button.text-button.image-button.titlebutton label:last-child, button.text-button.image-button label:last-child { - padding-left: 0; - padding-right: 16px; } - notebook > header > tabs > arrow.text-button.image-button image, headerbar button.text-button.image-button.titlebutton image, - .titlebar button.text-button.image-button.titlebutton image, button.text-button.image-button image { + padding-left: 8px; + padding-right: 8px; } + notebook > header > tabs > arrow.text-button.image-button label, headerbar button.text-button.image-button.titlebutton label, + .titlebar button.text-button.image-button.titlebutton label, button.text-button.image-button label { padding-left: 8px; padding-right: 8px; } button.osd { -- 2.30.2